﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ucThongTinNguoiDung.ascx.cs" Inherits="CuoiHoi.Admin.ucThongTinNguoiDung" %>

<div class="row">
    <div class="col-md-12">
        <div class="box">
            <div class="box-title">
                <h3>
                    <i class="icon-file"></i>
                    Thông tin người dùng
                </h3>
                <div class="box-tool">
                    <asp:Label Text="" ID="lbLoi" runat="server" BackColor="Red" />
                    <a href="#" data-action="collapse" target="_self">
                        <i class="icon-chevron-up"></i>
                    </a>
                    <a href="#" data-action="close" target="_self">
                        <i class="icon-remove"></i>
                    </a>
                </div>
            </div>

            <div class="box-content">
                <div class="row">
                    <div class="col-md-3">
                            <div class="col-sm-12 col-lg-12 controls">
                                <asp:Image ID="AnhDaiDien" runat="server" ImageUrl="~/images/default.png" Height="140px" Width="150px" CssClass="img-responsive" />
                                <asp:FileUpload ID="FileUpload1" runat="server" CssClass="hide" />
                        </div>

                        <br>
                        <br>
                    </div>
                    <div class="col-md-9 user-profile-info">
                        <p>
                            <span>Họ tên :</span>
                            <input class="form-control show-tooltip" type="text" runat="server" id="txtHoTen" data-original-title="Họ tên" data-trigger="hover">
                        </p>
                        <p>
                            <span>Tài khoản :</span>
                            <asp:Label Text="text" runat="server" class="form-control show-tooltip"  data-original-title="Tài khoản "  data-trigger="hover" ID="lbTenDangNhap" />
                        </p>
                        <p>
                            <span>Mật khẩu cũ :</span>
                            <input class="form-control show-tooltip"  type="password" runat="server" id="txtMatKhauCu" data-original-title="Mật khẩu cũ " data-trigger="hover">
                        </p>
                        <p>
                            <span>Mật khẩu mới :</span>
                            <input class="form-control show-tooltip" type="password"  runat="server" id="txtMatKhauMoi" data-original-title="Mật khẩu mới " data-trigger="hover">
                        </p>
                        
                        <p>
                            <span>Số điện thoại :</span>
                           <input class="form-control show-tooltip" type="text" runat="server" id="txtSoDienThoai" data-original-title="Số điện thoại " data-trigger="hover">
                        </p>
                        <p>
                            <span>Chức vụ :</span>
                          <input class="form-control show-tooltip" readonly="true" type="text" runat="server" id="txtChucVu" data-original-title="Chức vụ " data-trigger="hover">
                        </p>
                    </div>
                </div>

             <asp:Button ID="btnSua" runat="server" Text="Sửa thông tin"  CssClass="btn btn-primary" OnClick="btnSua_Click" />
             <button class="btn btn-primary" type="reset" data-dismiss="modal">Hủy</button>

            </div>

        </div>
    </div>
</div>

<script>
    function OpenUpload(fileUpload) {
        $(fileUpload).click();
    }

    $('#<%= AnhDaiDien.ClientID %>').click(function () {
         $('#<%= FileUpload1.ClientID%>').click();
    });
    $('#<%= FileUpload1.ClientID%>').change(function () {
        readURL(this, '#<%= AnhDaiDien.ClientID %>');
    });
    function readURL(input, imgAnhDaiDien) {

        if (input.files && input.files[0]) {
            var reader = new FileReader();
            reader.onload = function (e) {
                $(imgAnhDaiDien).attr('src', e.target.result);
            }
            reader.readAsDataURL(input.files[0]);
        }
    }
</script>

